package cn.wolfcode.crm.web.controller;

import cn.wolfcode.crm.domain.Employee;
import org.apache.shiro.SecurityUtils;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @program: crm
 * @description:
 * @author: Mr.chen
 * @create: 2018-07-09 13:13
 **/
@Controller
public class IndexController {
    @RequestMapping("index")
    public String index(Model model){
        Employee currentUser = (Employee) SecurityUtils.getSubject().getPrincipal();
        model.addAttribute("employee",currentUser);
        return "index";
    }

}
